import threading
import numpy as np


class MyThread(threading.Thread):
    def __init__(self, func, *args):
        super(MyThread, self).__init__()
        self.func = func
        print(args)
        self.args = args

    def run(self):
        self.func(*self.args)


def normalization(data):
    data = data * 1.0 / max(abs(data))
    return data
